import { createApp } from 'vue'
import './style.css'
import App from './App.vue'

// 引入路由
import router from './router'

// reset style sheet
import '@/styles/reset.scss'
// CSS common style sheet
import '@/styles/common.scss'
// element icons
import * as Icons from '@element-plus/icons-vue'
// custom element css
import '@/styles/element.scss'
// vue i18n
import I18n from "@/languages/index";
// 引入 pinia
import store from './store'
// custom directives
import directives from "@/directives/index";
// 使用 mock
import "./mock/index.js";

const app = createApp(App)

// 注册element Icons组件
Object.keys(Icons).forEach((key) => {
  app.component(key, Icons[key as keyof typeof Icons])
})

app.use(router).use(store).use(I18n).use(directives).mount('#app')
